<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
	<title>菜单管理</title>
	<%@ include file="layouts/top.jsp"%>
	
	<script type="text/javascript" charset="UTF-8" src="${ctx}/js/menus/Init.js"/></script>
	<script type="text/javascript" charset="UTF-8" src="${ctx}/js/menus/Event.js"/></script>
	<script type="text/javascript" charset="UTF-8" src="${ctx}/js/menus/Cmd.js"/></script>
</head>
<body>
	<div id="toolbar" class="search_bar">
		&nbsp;&nbsp;<span style="color: red;">父菜单:</span>
		<select id="parent_query" class="easyui-combobox" style="width:150px;"></select>
		<a href="###" class="easyui-linkbutton" onclick="query()" iconCls="icon-search">查询</a>
		<a href="###" class="easyui-linkbutton" iconCls="icon-add" plain="true" onclick="initAddMenu()">增加</a>
	</div>
	<table id="dg" title="查询列表" class="easyui-datagrid" toolbar="#toolbar"
		url="<c:url value="/system/getMenuList?parentCode=0"/>" rownumbers="true"
		fitColumns="true" singleSelect="true" pagination="true">
		<thead>
			<tr>
				<th field="menuName" width="60">菜单名称</th>
				<th field="menuCode" width="60">代码</th>
				<th field="menuUrl" width="75">菜单路径</th>
				<th field="menuOrder" width="35">菜单顺序</th>
				<th field="action" formatter="formatAction" width="125">操作</th>
			</tr>
		</thead>
	</table>

	<div id="dlg" class="easyui-dialog"
		style="width: 650px; height: auto; padding: 5px 5px;"
		closed="true" buttons="#dlg-buttons">
		<div align="left">
			<table class="formInfoTable" id="infoTable" width="100%">
				<tr>
					<td class="formInfoTable_LableCol">上级菜单</td>
					<td class="formInfoTable_StarCol">*</td>
					<td class="formInfoTable_InfoCol">
						<select id="parent_text" class="easyui-combobox" style="width:150px;"></select>
					</td>
				</tr>
				<tr>
					<td class="formInfoTable_LableCol">菜单代码</td>
					<td class="formInfoTable_StarCol"></td>
					<td class="formInfoTable_InfoCol">
						<input id="menuCode_text" style="width:150px;" />
					</td>
				</tr>
				<tr>
					<td class="formInfoTable_LableCol">菜单名称</td>
					<td class="formInfoTable_StarCol">*</td>
					<td class="formInfoTable_InfoCol">
						<input id="menuName_text" style="width:150px;" />
					</td>
				</tr>
				<tr>
					<td class="formInfoTable_LableCol">菜单路径</td>
					<td class="formInfoTable_StarCol">*</td>
					<td class="formInfoTable_InfoCol">
						<input id="menuUrl_text" style="width:150px;" />
					</td>
				</tr>
				<tr>
					<td class="formInfoTable_LableCol">菜单顺序</td>
					<td class="formInfoTable_StarCol">*</td>
					<td class="formInfoTable_InfoCol">
						<select id="menuOrder_text" class="easyui-combobox" style="width:150px;"></select>
					</td>
				</tr>
			</table>
		</div>
		<div id="dlg-buttons">
			<a href="#" class="easyui-linkbutton" iconCls="icon-ok" onclick="saveMenu()">保存</a>
			<a href="#" class="easyui-linkbutton" iconCls="icon-cancel" onclick="javascript:$('#dlg').dialog('close')">取消</a>
		</div>
	</div>
</body>
</html>